n = int(input())
d = {}
for i in range(n):
    i = input()
    if (d.get(i,False)):
        d[i] += 1
    else:
        d[i] = 1

print(max(d,key=d.get))
